package com.ln.cmsln.controller.zlxl.api;

import com.ln.cmsln.mapper.RemarksMapper;
import com.ln.cmsln.pojo.entity.Remarks;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

@CrossOrigin//跨域
@RestController
@RequestMapping("/apiremarks")
public class ApiRemarksController {

    @Resource
    private RemarksMapper remarksMapper ;

    @RequestMapping("getAll")
    public List<Remarks> getAll(){
        List<Remarks> remarks = remarksMapper.selectList(null);
        return remarks ;
    }

    @RequestMapping("getAllA")
    public List<Remarks> getAllA(){
        List<Remarks> remarks = remarksMapper.selectRemarksByCsidA();
        return remarks ;
    }
    @RequestMapping("getAllB")
    public List<Remarks> getAllB(){
        List<Remarks> remarks = remarksMapper.selectRemarksByCsidB();
        return remarks ;
    }

}
